<template>
  <div class="tools-container">
    <van-nav-bar title="gw-tools-app"
                 left-arrow
                 @click-left="()=>$router.go(-1)" />
    <van-cell-group v-for="(item,index) in list"
                    :key="index"
                    :title="item.title">
      <van-cell v-for="(item,index) in item.subList"
                :key="index"
                :title="item.title"
                :to="item.routerPath"
                is-link />
    </van-cell-group>
  </div>
</template>
<script>
import { Cell, CellGroup } from "vant";

export default {
  name: "gwAppVueTools",
  components: {
    [Cell.name]: Cell,
    [CellGroup.name]: CellGroup,
  },
  data() {
    return {
      list: [
        {
          title: "移动端",
          subList: [
            {
              title: "文字制定行数->展开收起",
              routerPath: "gwTextReadMoreView",
            },
            {
              title: "网络/本地图片->自适应宽高",
              routerPath: "gwAutoImageView",
            },
            {
              title: "文字前加图标",
              routerPath: "gwTextBeforeImgView",
            },
            {
              title: "vant底部文本随键盘输入评论框",
              routerPath: "gwTextareaCommontView",
            },
          ],
        },
      ],
    };
  },
};
</script>